home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Libris Britannia 4
/
science library(b).zip
/
science library(b)
/
DDJMAG
/
DDJ9203.ZIP
/
OOPASM.ZIP
/
STRINGS.ASM
< prev
next >
Wrap
Assembly Source File
|
1990-07-16
|
2KB
|
92 lines
.MODEL SMALL
INCLUDE equates.inc
INCLUDE instance.inc
INCLUDE objects.inc
IF1
INCLUDE macros.mac
INCLUDE cursor.mac
INCLUDE strings.mac
INCLUDE objects.mac
ENDIF
EXTRN Self:WORD
.CODE
PUBLIC prtString
COMMENT %
==============================================================================
Displays an ASCIIZ string at the current cursor position.
Passed: bl - Color
dx - Row/Column
si - Pointer to string
=============================================================================%
prtString PROC NEAR
pushData <cx,dx,si>
setCur dh,dl ;Position cursor
call prtString_ ;Display the string
popData <si,dx,cx>
ret
prtString ENDP
PUBLIC prtString_
COMMENT %
==============================================================================
Displays an ASCIIZ string at the current cursor position.
Passed: bl - Color
si - Pointer to string
=============================================================================%
prtString_ PROC NEAR
prtStrg si,bl ;Display the string
ret
prtString_ ENDP
PUBLIC disString
COMMENT %
==============================================================================
Displays the ASCIIZ string in the text buffer at the location, and with the
attributes currently at that locatioin.
=============================================================================%
disString PROC NEAR
getInst al,Row1,Self ;Get ptr to text row
getInst bl,Color ;Get text attribute
getInst bh,Col1 ;Get ptr to text column
getInst si,TxtPtr ;Get text pointer
disStrg al,bh,bl,si
ret
disString ENDP
PUBLIC disCharacter
COMMENT %
==============================================================================
Displays an ASCII character by writing to video memory.
Passed: bh - Character code
bl - Color
dx - Upper/Left row/column
=============================================================================%
disCharacter PROC NEAR
pushData <cx,di,dx>
disChar dh,dl,bl,bh ;Display character
popData <dx,di,cx>
ret
disCharacter ENDP
END